package routers

import (
	"gvb_server/api"
	"gvb_server/middleware"
)

func (router RouterGroup) BigModelRouter() {
	app := api.ApiGroupApp.BigModelApi
	router.GET("big_model/usable", middleware.JwtAdmin(), app.ModelUsableListView)

	router.GET("big_model/settings", app.ModelSettingView)
	router.PUT("big_model/settings", middleware.JwtAdmin(), app.ModelSettingUpdateView)

	router.GET("big_model/session_settings", middleware.JwtAdmin(), app.ModelSessionSettingView)
	router.PUT("big_model/session_settings", middleware.JwtAdmin(), app.ModelSessionSettingUpdateView)

	router.GET("big_model/user_scope_enable", middleware.JwtAuth(), app.UserScopeEnableView)
	router.POST("big_model/user_scope", middleware.JwtAuth(), app.UserScopeView)

	router.PUT("big_model/auto_reply", middleware.JwtAdmin(), app.AutoReplyUpdateView)
	router.GET("big_model/auto_reply", middleware.JwtAdmin(), app.AutoReplyListView)
	router.DELETE("big_model/auto_reply", middleware.JwtAdmin(), app.AutoReplyRemoveView)

	router.PUT("big_model/tags", middleware.JwtAdmin(), app.TagUpdateView)
	router.GET("big_model/tags", middleware.JwtAdmin(), app.TagListView)
	router.GET("big_model/tags/options", middleware.JwtAdmin(), app.TagOptionsListView)
	router.DELETE("big_model/tags", middleware.JwtAdmin(), app.TagRemoveView)

	router.GET("big_model/icons/options", app.IconsView)

	router.POST("big_model/roles", middleware.JwtAdmin(), app.RoleCreateView)
	router.PUT("big_model/roles", middleware.JwtAdmin(), app.RoleUpdateView)
	router.GET("big_model/roles", middleware.JwtAdmin(), app.RoleListView)
	router.DELETE("big_model/roles", middleware.JwtAdmin(), app.RoleRemoveView)
	router.GET("big_model/roles_detail", middleware.JwtAuth(), app.RoleDetailView)
	router.GET("big_model/roles_history", middleware.JwtAuth(), app.RoleUserHistoryListView)
	router.GET("big_model/role_sessions", middleware.JwtAuth(), app.RoleSessionsView)

	router.GET("big_model/square", app.TagRoleListView)
	router.POST("big_model/session", middleware.JwtAuth(), app.SessionCreateView)
	router.GET("big_model/session", middleware.JwtAuth(), app.SessionListView)
	router.PUT("big_model/session", middleware.JwtAuth(), app.SessionUserUpdateNameView)
	router.DELETE("big_model/session/:id", middleware.JwtAuth(), app.SessionUserRemoveView)
	router.DELETE("big_model/session", middleware.JwtAdmin(), app.SessionRemoveView)

	router.GET("big_model/chat_sse", app.ChatCreateView)
	router.GET("big_model/chat", middleware.JwtAuth(), app.ChatListView)
	router.DELETE("big_model/chat", middleware.JwtAdmin(), app.ChatRemoveView)
	router.DELETE("big_model/chat/:id", middleware.JwtAuth(), app.ChatUserRemoveView)
}
